<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>

<body>
  <script src="../js/axios.js"></script>
  <script>
    axios.get("???", { //delete
      params: { //通过params来传递参数
        id: "123"
      }
    }).then((ret) => {
      console.log(ret);
    });
    axios.get("????id=123").then((ret) => { //直接传递参数
      console.log(ret);
    });
  </script>
  <script>
    axios.post("???", { //put
      uname: "cz",
      age: 18
    }).then((ret) => {
      console.log(ret.data);
    });
  </script>
</body>

</html>